<?php
/**
 * *
 *  * ============================================================================
 *  * Created by PhpStorm.
 *  * User: Ice
 *  * 邮箱: ice@sbing.vip
 *  * 网址: https://sbing.vip
 *  * Date: 2019/9/19 下午3:33
 *  * ============================================================================.
 */

namespace app\api\controller;

use app\common\model\Upload;
use app\common\controller\Api;


/**
 * 公共接口.
 */
class Common extends Api
{
    protected $noNeedLogin = ['*'];
    protected $noNeedRight = '*';

   public function upload(){
       $file = request()->file('file');
       $data = Upload::uploadImages($file);
       $data['code'] == 200 ? $this->success($data['msg'],$data['data']) : $this->error($data['msg']);
   }
}
